webpackJsonp([37],{

/***/ "8Gcp":
/***/ (function(module, exports) {

// removed by extract-text-webpack-plugin

/***/ }),

/***/ "xlNz":
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
Object.defineProperty(__webpack_exports__, "__esModule", { value: true });

// EXTERNAL MODULE: ./node_modules/_babel-runtime@6.26.0@babel-runtime/core-js/promise.js
var promise = __webpack_require__("rVsN");
var promise_default = /*#__PURE__*/__webpack_require__.n(promise);

// EXTERNAL MODULE: ./node_modules/_babel-runtime@6.26.0@babel-runtime/helpers/slicedToArray.js
var slicedToArray = __webpack_require__("KH7x");
var slicedToArray_default = /*#__PURE__*/__webpack_require__.n(slicedToArray);

// EXTERNAL MODULE: ./node_modules/_babel-runtime@6.26.0@babel-runtime/regenerator/index.js
var regenerator = __webpack_require__("lC5x");
var regenerator_default = /*#__PURE__*/__webpack_require__.n(regenerator);

// EXTERNAL MODULE: ./node_modules/_babel-runtime@6.26.0@babel-runtime/helpers/asyncToGenerator.js
var asyncToGenerator = __webpack_require__("J0Oq");
var asyncToGenerator_default = /*#__PURE__*/__webpack_require__.n(asyncToGenerator);

// EXTERNAL MODULE: ./src/common/api/commonApi.js
var commonApi = __webpack_require__("+/+p");

// EXTERNAL MODULE: ./src/common/utils/index.js
var utils = __webpack_require__("dh3M");

// CONCATENATED MODULE: ./node_modules/_babel-loader@7.1.5@babel-loader/lib!./node_modules/_vue-loader@13.7.3@vue-loader/lib/selector.js?type=script&index=0!./src/common/anjian/message/detail.vue




//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//




/* harmony default export */ var detail = ({
  data: function data() {
    return {
      currentData: {},
      record: {}
    };
  },

  methods: {
    onSign: function onSign(loaded) {
      var _this = this;

      return asyncToGenerator_default()( /*#__PURE__*/regenerator_default.a.mark(function _callee() {
        return regenerator_default.a.wrap(function _callee$(_context) {
          while (1) {
            switch (_context.prev = _context.next) {
              case 0:
                _context.prev = 0;
                _context.next = 3;
                return commonApi["a" /* commonApi */].save('WJ_notice_bulletin_records', {
                  id: _this.record.id,
                  state: 1
                });

              case 3:
                _this.record.state = 1;
                _this.$Toast('签收成功!', 'success');
                _context.next = 10;
                break;

              case 7:
                _context.prev = 7;
                _context.t0 = _context['catch'](0);

                _this.$Toast('签收失败!', 'error');

              case 10:
                loaded();

              case 11:
              case 'end':
                return _context.stop();
            }
          }
        }, _callee, _this, [[0, 7]]);
      }))();
    }
  },
  activated: function activated() {
    var _this2 = this;

    return asyncToGenerator_default()( /*#__PURE__*/regenerator_default.a.mark(function _callee2() {
      var p, _ref, _ref2, department, data, record;

      return regenerator_default.a.wrap(function _callee2$(_context2) {
        while (1) {
          switch (_context2.prev = _context2.next) {
            case 0:
              p = [commonApi["a" /* commonApi */].dictionary('sending_department'), commonApi["a" /* commonApi */].searchById('WJ_notice_bulletin', _this2.$route.query.id), commonApi["a" /* commonApi */].searchById('WJ_notice_bulletin_records', _this2.$route.query.recordId)];
              _context2.next = 3;
              return promise_default.a.all(p);

            case 3:
              _ref = _context2.sent;
              _ref2 = slicedToArray_default()(_ref, 3);
              department = _ref2[0];
              data = _ref2[1];
              record = _ref2[2];

              _this2.record = record;
              _this2.currentData = Object(utils["d" /* ReplaceDictionary */])(data, {
                sending_department: department
              });

            case 10:
            case 'end':
              return _context2.stop();
          }
        }
      }, _callee2, _this2);
    }))();
  }
});
// CONCATENATED MODULE: ./node_modules/_vue-loader@13.7.3@vue-loader/lib/template-compiler?{"id":"data-v-6e14a2c6","hasScoped":true,"transformToRequire":{"video":["src","poster"],"source":"src","img":"src","image":"xlink:href"},"buble":{"transforms":{}}}!./node_modules/_vue-loader@13.7.3@vue-loader/lib/selector.js?type=template&index=0!./src/common/anjian/message/detail.vue
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('yt-page',{attrs:{"title":"通知公告详情","scroll":""}},[_c('yt-form',[_c('yt-card',{attrs:{"title":"基本信息"}},[_c('yt-cell',{attrs:{"label":"发文部门"}},[_vm._v(_vm._s(_vm.currentData.sending_department))]),_vm._v(" "),_c('yt-cell',{attrs:{"label":"公告标题"}},[_vm._v(_vm._s(_vm.currentData.bulletin_title))]),_vm._v(" "),_c('yt-cell',{attrs:{"label":"发文时间"}},[_vm._v(_vm._s(_vm._f("formatTime")(_vm.currentData.createdAt,'YYYY-MM-DD')))]),_vm._v(" "),_c('yt-cell',{attrs:{"label":"截止时间","border":"none"}},[_vm._v(_vm._s(_vm.currentData.end_time))])],1),_vm._v(" "),_c('yt-card',{attrs:{"title":"公告内容"}},[_c('div',{staticClass:"content"},[_vm._v("\n        "+_vm._s(_vm.currentData.bulletin_content)+"\n      ")])]),_vm._v(" "),_c('yt-card',{attrs:{"title":"公告附件"}},[_vm._l((_vm.currentData.file),function(file,index){return _c('yt-cell-open-file',{key:index,attrs:{"title":file.name,"url":file.url}},[_vm._v("\n        "+_vm._s(file.name)+"\n      ")])}),_vm._v(" "),(!_vm.currentData.file)?_c('p',{staticClass:"card-no-data"},[_vm._v("暂无附件")]):_vm._e()],2),_vm._v(" "),(_vm.record.state === 0)?_c('yt-btn',{attrs:{"slot":"btn","loading":_vm.onSign,"edge":""},slot:"btn"},[_vm._v("签收")]):_vm._e()],1)],1)}
var staticRenderFns = []
var esExports = { render: render, staticRenderFns: staticRenderFns }
/* harmony default export */ var message_detail = (esExports);
// CONCATENATED MODULE: ./src/common/anjian/message/detail.vue
function injectStyle (ssrContext) {
  __webpack_require__("8Gcp")
}
var normalizeComponent = __webpack_require__("C7Lr")
/* script */


/* template */

/* template functional */
var __vue_template_functional__ = false
/* styles */
var __vue_styles__ = injectStyle
/* scopeId */
var __vue_scopeId__ = "data-v-6e14a2c6"
/* moduleIdentifier (server only) */
var __vue_module_identifier__ = null
var Component = normalizeComponent(
  detail,
  message_detail,
  __vue_template_functional__,
  __vue_styles__,
  __vue_scopeId__,
  __vue_module_identifier__
)

/* harmony default export */ var anjian_message_detail = __webpack_exports__["default"] = (Component.exports);


/***/ })

});